
<!DOCTYPE HTML>
<html lang="" >
    <head>
        <meta charset="UTF-8">
        <meta content="text/html; charset=utf-8" http-equiv="Content-Type">
        <title>项目配置 · Diboot移动端基础项目</title>
        <meta http-equiv="X-UA-Compatible" content="IE=edge" />
        <meta name="description" content="">
        <meta name="generator" content="GitBook 3.2.3">
        
        
        
    
    <link rel="stylesheet" href="../gitbook/style.css">

    
            
                
                <link rel="stylesheet" href="../gitbook/gitbook-plugin-anchor-navigation-ex/style/plugin.css">
                
            
                
                <link rel="stylesheet" href="../gitbook/gitbook-plugin-highlight/website.css">
                
            
                
                <link rel="stylesheet" href="../gitbook/gitbook-plugin-search/search.css">
                
            
                
                <link rel="stylesheet" href="../gitbook/gitbook-plugin-fontsettings/website.css">
                
            
                
                <link rel="stylesheet" href="../gitbook/gitbook-plugin-theme-vuejs-2/vue.css">
                
            
        

    

    
        
    
        
    
        
    
        
    
        
    
        
    

        
    
    
    <meta name="HandheldFriendly" content="true"/>
    <meta name="viewport" content="width=device-width, initial-scale=1, user-scalable=no">
    <meta name="apple-mobile-web-app-capable" content="yes">
    <meta name="apple-mobile-web-app-status-bar-style" content="black">
    <link rel="apple-touch-icon-precomposed" sizes="152x152" href="../gitbook/images/apple-touch-icon-precomposed-152.png">
    <link rel="shortcut icon" href="../gitbook/images/favicon.ico" type="image/x-icon">

    
    <link rel="next" href="启动项目.html" />
    
    
    <link rel="prev" href="下载项目.html" />
    

    </head>
    <body>
        
<div class="book">
    <div class="book-summary">
        
            
<div id="book-search-input" role="search">
    <input type="text" placeholder="Type to search" />
</div>

            
                <nav role="navigation">
                



<ul class="summary">
    
    

    

    
        
        
    
        <li class="chapter " data-level="1.1" data-path="../">
            
                <a href="../">
            
                    
                    介绍
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.2" data-path="../开始.html">
            
                <a href="../开始.html">
            
                    
                    开始
            
                </a>
            

            
            <ul class="articles">
                
    
        <li class="chapter " data-level="1.2.1" data-path="环境准备.html">
            
                <a href="环境准备.html">
            
                    
                    环境准备
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.2.2" data-path="下载项目.html">
            
                <a href="下载项目.html">
            
                    
                    下载项目
            
                </a>
            

            
        </li>
    
        <li class="chapter active" data-level="1.2.3" data-path="项目配置.html">
            
                <a href="项目配置.html">
            
                    
                    项目配置
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.2.4" data-path="启动项目.html">
            
                <a href="启动项目.html">
            
                    
                    启动项目
            
                </a>
            

            
        </li>
    

            </ul>
            
        </li>
    
        <li class="chapter " data-level="1.3" data-path="../基础.html">
            
                <a href="../基础.html">
            
                    
                    基础
            
                </a>
            

            
            <ul class="articles">
                
    
        <li class="chapter " data-level="1.3.1" data-path="../基础/路由.html">
            
                <a href="../基础/路由.html">
            
                    
                    路由
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.3.2" data-path="../基础/过滤器.html">
            
                <a href="../基础/过滤器.html">
            
                    
                    过滤器
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.3.3" data-path="../基础/表单验证.html">
            
                <a href="../基础/表单验证.html">
            
                    
                    表单验证
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.3.4" data-path="../基础/接口数据格式.html">
            
                <a href="../基础/接口数据格式.html">
            
                    
                    接口数据格式
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.3.5" data-path="../基础/页面样式管理.html">
            
                <a href="../基础/页面样式管理.html">
            
                    
                    页面样式管理
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.3.6" data-path="../基础/展示列表数据.html">
            
                <a href="../基础/展示列表数据.html">
            
                    
                    展示列表数据
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.3.7" data-path="../基础/展示详情数据.html">
            
                <a href="../基础/展示详情数据.html">
            
                    
                    展示详情数据
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.3.8" data-path="../基础/添加新数据.html">
            
                <a href="../基础/添加新数据.html">
            
                    
                    添加新数据
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.3.9" data-path="../基础/更新数据.html">
            
                <a href="../基础/更新数据.html">
            
                    
                    更新数据
            
                </a>
            

            
        </li>
    

            </ul>
            
        </li>
    
        <li class="chapter " data-level="1.4" data-path="../组件.html">
            
                <a href="../组件.html">
            
                    
                    组件
            
                </a>
            

            
            <ul class="articles">
                
    
        <li class="chapter " data-level="1.4.1" data-path="../组件/图片上传.html">
            
                <a href="../组件/图片上传.html">
            
                    
                    图片上传
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.4.2" data-path="../组件/图片预览.html">
            
                <a href="../组件/图片预览.html">
            
                    
                    图片预览
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.4.3" data-path="../组件/关联数据列表选择.html">
            
                <a href="../组件/关联数据列表选择.html">
            
                    
                    关联数据列表选择
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.4.4" data-path="../组件/列表分页组件.html">
            
                <a href="../组件/列表分页组件.html">
            
                    
                    列表分页组件
            
                </a>
            

            
        </li>
    

            </ul>
            
        </li>
    

    

    <li class="divider"></li>

    <li>
        <a href="https://www.gitbook.com" target="blank" class="gitbook-link">
            Published with GitBook
        </a>
    </li>
</ul>



                </nav>
            
        
    </div>

    <div class="book-body">
        
            <div class="body-inner">
                

                    

<div class="book-header" role="navigation">
    

    <!-- Title -->
    <h1>
        <i class="fa fa-circle-o-notch fa-spin"></i>
        <a href=".." >项目配置</a>
    </h1>
</div>




                    <div class="page-wrapper" tabindex="-1" role="main">
                        <div class="page-inner">
                            
<div id="book-search-results">
    <div class="search-noresults">
    
                                <section class="normal markdown-section">
                                
                                <div id="anchor-navigation-ex-navbar"><i class="fa fa-navicon"></i><ul><li><span class="title-icon "></span><a href="#&#x9879;&#x76EE;&#x914D;&#x7F6E;"><b>1. </b>&#x9879;&#x76EE;&#x914D;&#x7F6E;</a></li><ul><li><span class="title-icon "></span><a href="#vue-cli&#x5F00;&#x53D1;&#x73AF;&#x5883;&#x914D;&#x7F6E;"><b>1.1. </b>vue-cli&#x5F00;&#x53D1;&#x73AF;&#x5883;&#x914D;&#x7F6E;</a></li><li><span class="title-icon "></span><a href="#&#x5185;&#x7F6E;&#x529F;&#x80FD;&#x914D;&#x7F6E;"><b>1.2. </b>&#x5185;&#x7F6E;&#x529F;&#x80FD;&#x914D;&#x7F6E;</a></li></ul></ul></div><a href="#&#x9879;&#x76EE;&#x914D;&#x7F6E;" id="anchorNavigationExGoTop"><i class="fa fa-arrow-up"></i></a><h1 id="&#x9879;&#x76EE;&#x914D;&#x7F6E;"><a name="&#x9879;&#x76EE;&#x914D;&#x7F6E;" class="anchor-navigation-ex-anchor" href="#&#x9879;&#x76EE;&#x914D;&#x7F6E;"><i class="fa fa-link" aria-hidden="true"></i></a>1. &#x9879;&#x76EE;&#x914D;&#x7F6E;</h1>
<h2 id="vue-cli&#x5F00;&#x53D1;&#x73AF;&#x5883;&#x914D;&#x7F6E;"><a name="vue-cli&#x5F00;&#x53D1;&#x73AF;&#x5883;&#x914D;&#x7F6E;" class="anchor-navigation-ex-anchor" href="#vue-cli&#x5F00;&#x53D1;&#x73AF;&#x5883;&#x914D;&#x7F6E;"><i class="fa fa-link" aria-hidden="true"></i></a>1.1. vue-cli&#x5F00;&#x53D1;&#x73AF;&#x5883;&#x914D;&#x7F6E;</h2>
<ul>
<li>vue&#x5F00;&#x53D1;&#x73AF;&#x5883;&#x76F8;&#x5173;&#x914D;&#x7F6E;&#x5728;&#x9879;&#x76EE;&#x6839;&#x76EE;&#x5F55;&#x4E0B;&#x7684; <a href="">vue.config.js</a> &#x914D;&#x7F6E;&#x6587;&#x4EF6;&#x4E2D;&#x3002;</li>
<li>&#x8FD9;&#x91CC;&#x9762;&#x7684;&#x76F8;&#x5173;&#x914D;&#x7F6E;&#x9879;&#xFF0C;&#x53EF;&#x4EE5;&#x6839;&#x636E;&#x81EA;&#x5DF1;&#x7684;&#x9700;&#x6C42;&#x6309;&#x7167;vue-cli&#x5B98;&#x7F51;&#x7684;&#x76F8;&#x5173;&#x65B9;&#x6CD5;&#x8FDB;&#x884C;&#x914D;&#x7F6E;&#x3002;</li>
<li><a href="">devServer</a> &#x4E3A;&#x5F00;&#x53D1;&#x73AF;&#x5883;&#x4E2D;&#x5BF9;&#x6570;&#x636E;&#x63A5;&#x53E3;&#x7684;&#x4EE3;&#x7406;&#x8BBE;&#x7F6E;&#x3002;</li>
</ul>
<pre><code class="lang-javascript"><span class="hljs-built_in">module</span>.exports = {
  baseUrl: <span class="hljs-string">&apos;/&apos;</span>,
  outputDir: <span class="hljs-string">&apos;dist&apos;</span>,
  assetsDir: <span class="hljs-string">&apos;static&apos;</span>,
  devServer: {
    disableHostCheck: <span class="hljs-literal">true</span>,
    port: <span class="hljs-number">80</span>,
    proxy: {
      <span class="hljs-string">&apos;/rest&apos;</span>: {
        target: <span class="hljs-string">&apos;http://localhost:8080/rest&apos;</span>,
        changeOrigin: <span class="hljs-literal">true</span>,
        pathRewrite: {
          <span class="hljs-string">&apos;^/rest&apos;</span>: <span class="hljs-string">&apos;/&apos;</span>,
        },
      },
    },
  },
};
</code></pre>
<h2 id="&#x5185;&#x7F6E;&#x529F;&#x80FD;&#x914D;&#x7F6E;"><a name="&#x5185;&#x7F6E;&#x529F;&#x80FD;&#x914D;&#x7F6E;" class="anchor-navigation-ex-anchor" href="#&#x5185;&#x7F6E;&#x529F;&#x80FD;&#x914D;&#x7F6E;"><i class="fa fa-link" aria-hidden="true"></i></a>1.2. &#x5185;&#x7F6E;&#x529F;&#x80FD;&#x914D;&#x7F6E;</h2>
<p>&#x5185;&#x7F6E;&#x529F;&#x80FD;&#x914D;&#x7F6E;&#x5728; <a href="">src/config/index.js</a> &#x6587;&#x4EF6;&#x4E2D;</p>
<ul>
<li><a href="">authType</a> &#x8BA4;&#x8BC1;&#x65B9;&#x5F0F;&#xFF0C;&#x5373;&#x767B;&#x5F55;&#x65B9;&#x5F0F;&#xFF0C;&#x76EE;&#x524D;&#x652F;&#x6301;&#x5FAE;&#x4FE1;&#x6388;&#x6743;&#x548C;&#x7528;&#x6237;&#x540D;&#x5BC6;&#x7801;&#x767B;&#x5F55;&#xFF0C;&#x4E5F;&#x53EF;&#x4EE5;&#x81EA;&#x5B9A;&#x4E49;&#x3002;</li>
<li><a href="">AUTH_TYPE</a> &#x4E3A;&#x8BA4;&#x8BC1;&#x65B9;&#x5F0F;&#x5F15;&#x7528;&#x5BF9;&#x8C61;&#xFF0C;&#x5982;&#x679C;&#x6709;&#x81EA;&#x5B9A;&#x4E49;&#x7684;&#x767B;&#x5F55;&#x65B9;&#x5F0F;&#xFF0C;&#x53EF;&#x4EE5;&#x589E;&#x52A0;&#x5230;&#x8BE5;&#x5BF9;&#x8C61;&#x4E2D;&#x3002;</li>
<li><a href="">authHeaderKey</a> &#x4E3A;&#x4F5C;&#x4E3A;&#x8BF7;&#x6C42;&#x5934;&#x4E2D;&#x643A;&#x5E26;token&#x7684;&#x5B57;&#x6BB5;&#x540D;&#xFF0C;&#x9ED8;&#x8BA4;&#x4E3A; <a href="">authtoken</a> &#x3002;</li>
<li><a href="">AUTH_REFRESH_INTERVAL</a> &#x4E3A;token&#x5237;&#x65B0;&#x95F4;&#x9694;&#xFF0C;&#x4E3A;&#x4E86;&#x9632;&#x6B62;&#x9875;&#x9762;&#x83B7;&#x53D6;&#x6570;&#x636E;&#x63D0;&#x4EA4;&#x7B49;&#x51FA;&#x73B0;&#x6388;&#x6743;&#x4E8B;&#x53D8;&#xFF0C;&#x4F1A;&#x5B9A;&#x65F6;&#x5237;&#x65B0;token&#xFF0C;&#x786E;&#x4FDD;&#x9875;&#x9762;&#x4E0D;&#x8FC7;&#x671F;&#x3002;&#x9ED8;&#x8BA4;&#x4E3A;<a href="">30&#x5206;&#x949F;</a>&#xFF0C;&#x53EF;&#x81EA;&#x884C;&#x8BBE;&#x7F6E;&#xFF0C;&#x6BEB;&#x79D2;&#x4E3A;&#x5355;&#x4F4D;&#x3002;</li>
<li><a href="">requestTimeout</a> &#x8BF7;&#x6C42;&#x6570;&#x636E;&#x65F6;&#x7684;&#x8D85;&#x65F6;&#x65F6;&#x95F4;&#x8BBE;&#x7F6E;&#xFF0C;&#x9ED8;&#x8BA4;&#x4E3A;10&#x79D2;&#x3002;</li>
<li><a href="">TOKEN_API</a> &#x4F7F;&#x7528;&#x7528;&#x6237;&#x540D;&#x5BC6;&#x7801;&#x767B;&#x5F55;&#x65F6;&#x767B;&#x5F55;&#x63A5;&#x53E3;&#x5730;&#x5740;&#x3002;</li>
<li><a href="">WECHAT_TOKEN_API</a> &#x4F7F;&#x7528;&#x5FAE;&#x4FE1;&#x6388;&#x6743;&#x767B;&#x5F55;&#x65F6;&#x901A;&#x8FC7;code&#x548C;state&#x8FDB;&#x884C;token&#x8BA4;&#x8BC1;&#x7684;&#x63A5;&#x53E3;&#x5730;&#x5740;&#x3002;</li>
<li><a href="">GET_WEIXIN_JSSDK_API</a> &#x83B7;&#x53D6;JS_SDK&#x521D;&#x59CB;&#x5316;&#x4FE1;&#x606F;&#x7684;&#x63A5;&#x53E3;&#x5730;&#x5740;&#x3002;</li>
<li><a href="">noneAuthList</a> &#x4E0D;&#x9700;&#x8981;&#x767B;&#x5F55;&#x5C31;&#x53EF;&#x4EE5;&#x83B7;&#x53D6;&#x6570;&#x636E;&#x7684;&#x8DEF;&#x7531;&#x5217;&#x8868;&#xFF08;&#x586B;&#x5199;&#x8DEF;&#x7531;&#x540D;&#x5373;&#x53EF;&#xFF09;&#x3002;</li>
</ul>

                                
                                </section>
                            
    </div>
    <div class="search-results">
        <div class="has-results">
            
            <h1 class="search-results-title"><span class='search-results-count'></span> results matching "<span class='search-query'></span>"</h1>
            <ul class="search-results-list"></ul>
            
        </div>
        <div class="no-results">
            
            <h1 class="search-results-title">No results matching "<span class='search-query'></span>"</h1>
            
        </div>
    </div>
</div>

                        </div>
                    </div>
                

            </div>

            
                
                <a href="下载项目.html" class="navigation navigation-prev " aria-label="Previous page: 下载项目">
                    <i class="fa fa-angle-left"></i>
                </a>
                
                
                <a href="启动项目.html" class="navigation navigation-next " aria-label="Next page: 启动项目">
                    <i class="fa fa-angle-right"></i>
                </a>
                
            
        
    </div>

    <script>
        var gitbook = gitbook || [];
        gitbook.push(function() {
            gitbook.page.hasChanged({"page":{"title":"项目配置","level":"1.2.3","depth":2,"next":{"title":"启动项目","level":"1.2.4","depth":2,"path":"开始/启动项目.md","ref":"开始/启动项目.md","articles":[]},"previous":{"title":"下载项目","level":"1.2.2","depth":2,"path":"开始/下载项目.md","ref":"开始/下载项目.md","articles":[]},"dir":"ltr"},"config":{"plugins":["-sharing","sharing-plus","anchor-navigation-ex","theme-vuejs-2"],"styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"pluginsConfig":{"search":{},"sharing-plus":{"qq":false,"all":["facebook","google","twitter","instapaper","linkedin","pocket","stumbleupon"],"douban":false,"facebook":true,"weibo":false,"instapaper":false,"whatsapp":false,"hatenaBookmark":false,"twitter":true,"messenger":false,"line":false,"vk":false,"pocket":true,"google":false,"viber":false,"stumbleupon":false,"qzone":false,"linkedin":false},"lunr":{"maxIndexSize":1000000,"ignoreSpecialCharacters":false},"theme-vuejs-2":{},"fontsettings":{"theme":"white","family":"sans","size":2},"highlight":{},"anchor-navigation-ex":{"mode":"float","pageTop":{"level1Icon":"","level2Icon":"","level3Icon":"","showLevelIcon":false},"showLevel":true,"tocLevel1Icon":"fa fa-hand-o-right","tocLevel2Icon":"fa fa-hand-o-right","tocLevel3Icon":"fa fa-hand-o-right","showGoTop":true,"isShowTocTitleIcon":true,"printLog":false,"multipleH1":true,"associatedWithSummary":true,"float":{"floatIcon":"fa fa-navicon","level1Icon":"","level2Icon":"","level3Icon":"","showLevelIcon":false}},"sharing":{"qq":true,"all":["weibo","qq","linkedin","qzone","douban"],"douban":false,"weibo":true,"instapaper":false,"whatsapp":false,"hatenaBookmark":false,"twitter":false,"messenger":false,"line":false,"vk":false,"pocket":false,"viber":false,"stumbleupon":false,"qzone":true,"linkedin":false},"theme-default":{"styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"showLevel":false}},"theme":"default","pdf":{"pageNumbers":true,"fontSize":12,"fontFamily":"Arial","paperSize":"a4","chapterMark":"pagebreak","pageBreaksBefore":"/","margin":{"right":62,"left":62,"top":56,"bottom":56}},"structure":{"langs":"LANGS.md","readme":"README.md","glossary":"GLOSSARY.md","summary":"SUMMARY.md"},"variables":{},"title":"Diboot移动端基础项目","gitbook":"*","description":"Diboot移动端基础项目"},"file":{"path":"开始/项目配置.md","mtime":"2018-11-08T08:51:40.895Z","type":"markdown"},"gitbook":{"version":"3.2.3","time":"2018-11-10T15:10:03.285Z"},"basePath":"..","book":{"language":""}});
        });
    </script>
</div>

        
    <script src="../gitbook/gitbook.js"></script>
    <script src="../gitbook/theme.js"></script>
    
        
        <script src="../gitbook/gitbook-plugin-sharing-plus/buttons.js"></script>
        
    
        
        <script src="../gitbook/gitbook-plugin-search/search-engine.js"></script>
        
    
        
        <script src="../gitbook/gitbook-plugin-search/search.js"></script>
        
    
        
        <script src="../gitbook/gitbook-plugin-lunr/lunr.min.js"></script>
        
    
        
        <script src="../gitbook/gitbook-plugin-lunr/search-lunr.js"></script>
        
    
        
        <script src="../gitbook/gitbook-plugin-fontsettings/fontsettings.js"></script>
        
    

    </body>
</html>

